class Group < ActiveRecord::Base
  has_many :user
  has_many :authentication
  has_many :permissions ,  :through => :authentication
  
  validates_presence_of :name
  validates_uniqueness_of :name
  validates_length_of :description , :maximum =>128
  
  attr_accessor :user_log
  def to_audit
    return "ID:#{id}"+","+"Name:#{name}"+","+"Description:#{description}"
  end
end
